package tests;

import org.junit.Test;

import classes.B;
import classes.D;


public class NegativeTest {

	@Test
	public void testParameterConstructorSucess() {
		new D(10.0f, -5);
	}

	@Test
	public void testParameterConstructorFailure() {
		new D(5.3f, 5);
	}

	@Test
	public void testFieldAttributionLevelClassSucess() {
		D obj = new D(10, -5);
		obj.setValue2(-10.2);
	}

	@Test
	public void testFieldAttributionLevelClassFailure() {
		D obj = new D(10, -5);
		obj.setValue2(5.4);
	}

	@Test
	public void testDoubleFieldAttributionLevelClassSucess() {
		D obj = new D(10, -5);
		obj.setValue6(-10.5f);
	}

	@Test
	public void testDoubleFieldAttributionLevelClassFailure() {
		D obj = new D(10, -5);
		obj.setValue6(10.3f);
	}

	@Test
	public void testGetFieldLevelClassSucess() {
		D obj = new D(10, -5);
		obj.setValue4(-4);
		obj.getValue4();
	}

	@Test
	public void testGetFieldLevelClassFailure() {
		D obj = new D(10, -5);
		obj.setValue4(4);
		obj.getValue4();
	}

	@Test
	public void testFieldAttributionLevelInterfaceSucess() {
		B obj = new B(10, -5);
		obj.setValue2(-10.2);
	}

	@Test
	public void testFieldAttributionLevelInterfaceFailure() {
		B obj = new B(10, -5);
		obj.setValue2(5.2);
	}

	@Test
	public void testDoubleFieldAttributionLevelInterfaceSucess() {
		B obj = new B(10, -5);
		obj.setValue6(-10.5f);
	}

	@Test
	public void testDoubleFieldAttributionLevelInterfaceFailure() {
		B obj = new B(10, -5);
		obj.setValue6(10.3f);
	}

	@Test
	public void testGetFieldLevelInterfaceSucess() {
		B obj = new B(10, -5);
		obj.setValue4(-4);
		obj.getValue4();
	}

	@Test
	public void testGetFieldLevelInterfaceFailure() {
		B obj = new B(10, -5);
		obj.setValue4(4);
		obj.getValue4();
	}

}
